/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor..
 */
package proyecto1;

import java.util.Calendar;
import javax.swing.DefaultComboBoxModel;
import javax.swing.JButton;
import javax.swing.JSpinner;
import javax.swing.JToggleButton;
import javax.swing.SpinnerModel;
import javax.swing.SpinnerNumberModel;
import javax.swing.table.DefaultTableModel;

/**
 *
 * @author grupo
 */
public class InterfazUsuario extends javax.swing.JFrame {

    private DefaultTableModel modeloTablaPlanes;
    private DefaultTableModel modeloTablaActividades;
    private Gestor gestor;
    private Calendar calendario;
    private Calendar fechaPropuestaActividad;
    private DefaultComboBoxModel modeloOriginador;
    private DefaultComboBoxModel modeloAdministrador;
    private DefaultComboBoxModel modeloLider;
    private DefaultComboBoxModel modeloAuditor;

    private DefaultComboBoxModel modeloSucursale;

    /**
     * Creates new form InterfazUsuario
     */
    public InterfazUsuario() {
        initComponents();
    }

    /**
     * @return the modeloTablaPlanes
     */
    private DefaultTableModel getModeloTablaPlanes() {
        return modeloTablaPlanes;
    }

    /**
     * @return the modeloTablaActividades
     */
    private DefaultTableModel getModeloTablaActvidades() {
        return getModeloTablaActividades();
    }

    private javax.swing.JButton getJbCrearPlan() {
        return this.jbCrearPlan;
    }

    /**
     * @param modeloTablaPlanes the modeloTablaPlanes to set
     */
    private void setModeloTablaPlanes(DefaultTableModel modeloTablaPlanes) {
        this.modeloTablaPlanes = modeloTablaPlanes;
    }

    /**
     * @param modeloTablaActividades the modeloTablaActividades to set
     */
    private void setModeloTablaActividades(DefaultTableModel modeloTablaActvidades) {
        this.modeloTablaActividades = modeloTablaActvidades;
    }

    /**
     *
     * @param pGestor
     */
    public void setGestor(Gestor pGestor) {
        gestor = pGestor;
    }

    /**
     *
     * @param pOriginador
     */
    public void addCBItemOriginador(String pOriginador) {
        this.modeloOriginador.addElement(pOriginador);
    }

    /**
     *
     * @param pOrig
     */
    public void setTFOriginador(String pOrig) {
        this.jcbOriginador.setSelectedItem(pOrig);
    }

    /**
     *
     * @return
     */
    public String getTFOriginador() {
        return (String) this.jcbOriginador.getSelectedItem();
    }

    /**
     *
     * @param pSucursal
     */
    public void addCBItemSucursal(String pSucursal) {
        this.modeloSucursale.addElement(pSucursal);
    }

    /**
     *
     * @param pSucursal
     */
    public void setTFSucursal(String pSucursal) {
        this.jcbSucursales.setSelectedItem(pSucursal);
    }

    /**
     *
     * @return
     */
    public String getTFSucursal() {
        return (String) this.jcbSucursales.getSelectedItem();
    }

    /**
     *
     * @return
     */
    public String getResolucionAuditoria() {
        return this.jtaResolucionAuditor.getText();
    }

    /**
     *
     * @return
     */
    public boolean getResolucionAuditor() {
        return this.jrbEfectivo.isSelected();
    }

    /**
     *
     * @return
     */
    public boolean isPlanMarcadoResuelto() {
        return this.jtbMarcarPlanResuelto.getModel().isSelected();
    }

    /**
     *
     * @param set
     */
    public void setPlanMarcadoResuelto(boolean set) {
        this.jtbMarcarPlanResuelto.getModel().setSelected(set);
    }

    /**
     *
     * @param pAdministrador
     */
    public void addCBItemAdministrador(String pAdministrador) {
        this.modeloAdministrador.addElement(pAdministrador);
    }

    /**
     *
     * @param pAdmin
     */
    public void setTFAdministrador(String pAdmin) {
        this.jcbAdministrador.setSelectedItem(pAdmin);
    }

    /**
     *
     * @return
     */
    public String getTFAdministrador() {
        return (String) this.jcbAdministrador.getSelectedItem();
    }

    /**
     *
     * @param pLider
     */
    public void addCBItemLider(String pLider) {
        this.modeloLider.addElement(pLider);
    }

    /**
     *
     * @param pLider
     */
    public void setTFLider(String pLider) {
        this.jcbLider.setSelectedItem(pLider);
    }

    /**
     *
     * @return
     */
    public String getTFLider() {
        return (String) this.jcbLider.getSelectedItem();
    }

    /**
     *
     * @param pAuditor
     */
    public void setTFAuditor(String pAuditor) {
        this.jcbAuditor.setSelectedItem(pAuditor);
    }

    /**
     *
     * @param pAuditor
     */
    public void addCBItemAuditor(String pAuditor) {
        this.modeloAuditor.addElement(pAuditor);
    }

    /**
     *
     * @return
     */
    public String getTFAuditor() {
        return (String) this.jcbAuditor.getSelectedItem();
    }

    /**
     *
     * @param pEstado
     */
    public void setTFEstado(String pEstado) {
        this.lblSatus.setText(pEstado);
    }

    /**
     *
     * @return
     */
    public Calendar getFechaPropuestaActividad() {

        int dia = (int) jsDia.getValue();
        int mes = (int) jsMes.getValue();
        int anio = (int) jsAnio.getValue();

        fechaPropuestaActividad.set(anio, mes-1, dia);

        return this.fechaPropuestaActividad;
    }

    /**
     *
     * @param tipo
     */
    public void setRBTipoPlan(TipoDePlan tipo) {
        if (tipo == tipo.CORRECTIVO) {
            this.jrbCorrectivo.setSelected(true);
        } else {
            this.jrbPreventivo.setSelected(true);
        }
    }

   public void setTBCerrarPlanMarcado(boolean activo)
   {
       this.jtbMarcarPlanResuelto.setSelected(activo);
   }

    /**
     *
     * @param estado
     */
    public void setTFEstadoPlan(String estado) {
        this.jtfEstado.setText(estado);
    }

    /**
     *
     * @return
     */
    public String getPlanSeleccionadoDeTabla() {
        int row = this.getJtPlanes().getSelectedRow();
        return (String) getModeloTablaPlanes().getValueAt(row, 0);
    }
    
    /**
     *
     * @return
     */
    public int getActividadSeleccionadaDeTabla()
    {
        return this.getJtActividades().getSelectedRow();
    }

    /**
     *
     * @param row
     */
    public void setPlanSeleccionadoEnTabla(int row) {
        this.getJtPlanes().getSelectionModel().setSelectionInterval(row, row);
    }
    
    /**
     *
     * @param row
     */
    public void setActividadSeleccionadaEnTabla(int row)
    {
        this.getJtActividades().getSelectionModel().setSelectionInterval(row, row);
    }

    /**
     * @param jbCrearPlan the jbCrearPlan to set
     */
    private void setJbCrearPlan(javax.swing.JButton jbCrearPlan) {
        this.jbCrearPlan = jbCrearPlan;
    }

    /**
     *
     * @param pDesc
     */
    public void setTADescripcionActividad(String pDesc) {
        this.jtaDescripcionActividad.setText(pDesc);
    }

    /**
     *
     * @param Originador
     */
    public void agregarLineaTabla(String[] Originador) {
        this.getModeloTablaPlanes().addRow(Originador);
    }

    /**
     *
     * @param Originador
     */
    public void agregarLineaTabla2(String[] Originador) {
        this.getModeloTablaActvidades().addRow(Originador);
    }

    /**
     *
     * @return
     */
    public String obtenerNombreSucursal() {
        return this.jcbSucursales.getSelectedItem().toString();
    }

    /**
     *
     * @return
     */
    public TipoDePlan obtenerTipoPlan() {
        if (this.bgTipoPlan.isSelected(this.jrbCorrectivo.getModel())) {
            return TipoDePlan.CORRECTIVO;
        } else {
            return TipoDePlan.PREVENTIVO;
        }
    }

    /**
     *
     * @return
     */
    public String obtenerDescripcionPlan() {
        return this.jtaDescripcionPlan.getText();
    }

    /**
     *
     * @return
     */
    public String obtenerDescripcionActvidad() {
        return this.jtaDescripcionActividad.getText();
    }

    /**
     * @return 
     */
    public JButton getJbAgregarActividad() {
        return jbAgregarActividad;
    }

    /**
     *
     * @param jbAgregarActividad
     */
    public void setJbAgregarActividad(JButton jbAgregarActividad) {
        this.jbAgregarActividad = jbAgregarActividad;
    }

    /**
     *
     * @return
     */
    public JButton getJbCerrarActividad() {
        return jbCerrarActividad;
    }

    /**
     *
     * @param jbCerrarActividad
     */
    public void setJbCerrarActividad(JButton jbCerrarActividad) {
        this.jbCerrarActividad = jbCerrarActividad;
    }

    /**
     *
     * @return
     */
    public String getActividadSeleccionadoDeTabla() {
        int row = this.getJtActividades().getSelectedRow();
        return (String) getModeloTablaPlanes().getValueAt(row, 0);
    }

    /**
     *
     * @param row
     */
    public void setActividadSeleccionadoEnTabla(int row) {
        this.getJtActividades().getSelectionModel().setSelectionInterval(row, row);
    }

    /**
     *
     * @param pCant
     */
    public void setTFCantidadPlanesRegistrados(String pCant) {
        this.jtfCantidadPlanesRegistrados.setText(pCant);
    }

    /**
     *
     * @param pCant
     */
    public void setTFCantidadPlanesEfectivos(String pCant) {
        this.jtfCantPlanesEfectivos.setText(pCant);
    }

    /**
     *
     * @param pCant
     */
    public void setTFCantidadPlanesInefectivos(String pCant) {
        this.jtfCantInefectivos.setText(pCant);
    }

    /**
     *
     * @param indice
     */
    public void setTFIndicePrevisionGlobal(String indice) {
        this.jtfIndicePrevisionGlobal.setText(indice);
    }

    /**
     *
     * @param sucursal
     */
    public void setTFSucursalMayorPrevision(String sucursal) {
        this.jtfSucursalMayorPrevision.setText(sucursal);
    }

    /**
     *
     * @param sucursal
     */
    public void setTFSucursalMayorPlanesCorrectivos(String sucursal) {
        this.jtfSucursalMayorPlanesCorrectivos.setText(sucursal);
    }

    /**
     *
     * @param sucursal
     */
    public void setTFSucursalMayorPlanesPreventivos(String sucursal) {
        this.jtfSucursalMayorPlanesPreventivos.setText(sucursal);
    }

    /**
     *
     * @param indice
     */
    public void setTFIndicadorEficienciaGlobal(String indice) {
        this.jtfIndicadorEficienciaGlobal.setText(indice);
    }

    /**
     *
     * @param indice
     */
    public void setTFIndicadorEficaciaGlobal(String indice) {
        this.jtfIndicadorEfectividadGlobal.setText(indice);
    }
    
    /**
     *
     * @param pCant
     */
    public void setTFPlanesRegistradosSucursal1(String pCant)
    {
        this.jtfPlanesSucursal1.setText(pCant);
    }
    
    /**
     *
     * @param ind
     */
    public void setTFIndicePrevisionSuc1(String ind)
    {
        this.jtfIndicePrevisionSuc1.setText(ind);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesCorrectivosSuc1(String cant)
    {
        this.jtfPlanesCorrectivosSuc1.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesPreventivosSuc1(String cant)
    {
        this.jtfPlanesPreventivosSuc1.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficienciaSuc1(String cant)
    {
        this.jtfIndicadorEficienciaSuc1.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficaciaSuc1(String cant)
    {
        this.jtfIndicadorEficaciaSuc1.setText(cant);
    }
    
    /**
     *
     * @param pCant
     */
    public void setTFPlanesRegistradosSucursal2(String pCant)
    {
        this.jtfPlanesSucursal2.setText(pCant);
    }
    
    /**
     *
     * @param ind
     */
    public void setTFIndicePrevisionSuc2(String ind)
    {
        this.jtfIndicePrevisionSuc2.setText(ind);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesCorrectivosSuc2(String cant)
    {
        this.jtfPlanesCorrectivosSuc2.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesPreventivosSuc2(String cant)
    {
        this.jtfPlanesPreventivosSuc2.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficienciaSuc2(String cant)
    {
        this.jtfIndicadorEficienciaSuc2.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficaciaSuc2(String cant)
    {
        this.jtfIndicadorEficaciaSuc2.setText(cant);
    }
    
    /**
     *
     * @param pCant
     */
    public void setTFPlanesRegistradosSucursal3(String pCant)
    {
        this.jtfPlanesSucursal3.setText(pCant);
    }
    
    /**
     *
     * @param ind
     */
    public void setTFIndicePrevisionSuc3(String ind)
    {
        this.jtfIndicePrevisionSuc3.setText(ind);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesCorrectivosSuc3(String cant)
    {
        this.jtfPlanesCorrectivosSuc3.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesPreventivosSuc3(String cant)
    {
        this.jtfPlanesPreventivosSuc3.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficienciaSuc3(String cant)
    {
        this.jtfIndicadorEficienciaSuc3.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficaciaSuc3(String cant)
    {
        this.jtfIndicadorEficaciaSuc3.setText(cant);
    }
    
    /**
     *
     * @param pCant
     */
    public void setTFPlanesRegistradosSucursal4(String pCant)
    {
        this.jtfPlanesSucursal4.setText(pCant);
    }
    
    /**
     *
     * @param ind
     */
    public void setTFIndicePrevisionSuc4(String ind)
    {
        this.jtfIndicePrevisionSuc4.setText(ind);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesCorrectivosSuc4(String cant)
    {
        this.jtfPlanesCorrectivosSuc4.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFPlanesPreventivosSuc4(String cant)
    {
        this.jtfPlanesPreventivosSuc4.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficienciaSuc4(String cant)
    {
        this.jtfIndicadorEficienciaSuc4.setText(cant);
    }
    
    /**
     *
     * @param cant
     */
    public void setTFIndicadorEficaciaSuc4(String cant)
    {
        this.jtfIndicadorEficaciaSuc4.setText(cant);
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        bgTipoPlan = new javax.swing.ButtonGroup();
        bgPlanEfectivo = new javax.swing.ButtonGroup();
        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel2 = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        jtaDescripcionPlan = new javax.swing.JTextArea();
        jLabel2 = new javax.swing.JLabel();
        jcbSucursales = new javax.swing.JComboBox();
        jLabel3 = new javax.swing.JLabel();
        jrbPreventivo = new javax.swing.JRadioButton();
        jrbCorrectivo = new javax.swing.JRadioButton();
        jPanel1 = new javax.swing.JPanel();
        jLabel4 = new javax.swing.JLabel();
        jbCrearPlan = new javax.swing.JButton();
        jbAsignarAdmin = new javax.swing.JButton();
        jbAsignarLider = new javax.swing.JButton();
        jbAsignarAuditor = new javax.swing.JButton();
        jLabel7 = new javax.swing.JLabel();
        jLabel6 = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        jcbOriginador = new javax.swing.JComboBox();
        jcbAdministrador = new javax.swing.JComboBox();
        jcbLider = new javax.swing.JComboBox();
        jcbAuditor = new javax.swing.JComboBox();
        jLabel8 = new javax.swing.JLabel();
        jtfEstado = new javax.swing.JTextField();
        jPanel3 = new javax.swing.JPanel();
        jLabel9 = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jtaResolucionAuditor = new javax.swing.JTextArea();
        jLabel10 = new javax.swing.JLabel();
        jrbEfectivo = new javax.swing.JRadioButton();
        jrbInefectivo = new javax.swing.JRadioButton();
        jbCerrarAuditoria = new javax.swing.JButton();
        jtbMarcarPlanResuelto = new javax.swing.JToggleButton();
        jPanel4 = new javax.swing.JPanel();
        jLabel11 = new javax.swing.JLabel();
        jScrollPane3 = new javax.swing.JScrollPane();
        jtaDescripcionActividad = new javax.swing.JTextArea();
        jpFecha = new javax.swing.JPanel();
        jLabel12 = new javax.swing.JLabel();
        jsDia = new javax.swing.JSpinner();
        jLabel13 = new javax.swing.JLabel();
        jsMes = new javax.swing.JSpinner();
        jLabel14 = new javax.swing.JLabel();
        jsAnio = new javax.swing.JSpinner();
        jbAgregarActividad = new javax.swing.JButton();
        jbCerrarActividad = new javax.swing.JButton();
        jScrollPane4 = new javax.swing.JScrollPane();
        jtActividades = new javax.swing.JTable();
        jScrollPane5 = new javax.swing.JScrollPane();
        jtPlanes = new javax.swing.JTable();
        lblSatus = new java.awt.Label();
        jPanel5 = new javax.swing.JPanel();
        jPanel6 = new javax.swing.JPanel();
        jLabel24 = new javax.swing.JLabel();
        jLabel25 = new javax.swing.JLabel();
        jLabel26 = new javax.swing.JLabel();
        jLabel27 = new javax.swing.JLabel();
        jLabel28 = new javax.swing.JLabel();
        jLabel29 = new javax.swing.JLabel();
        jtfPlanesSucursal1 = new javax.swing.JTextField();
        jtfIndicePrevisionSuc1 = new javax.swing.JTextField();
        jtfPlanesCorrectivosSuc1 = new javax.swing.JTextField();
        jtfPlanesPreventivosSuc1 = new javax.swing.JTextField();
        jtfIndicadorEficienciaSuc1 = new javax.swing.JTextField();
        jtfIndicadorEficaciaSuc1 = new javax.swing.JTextField();
        jPanel7 = new javax.swing.JPanel();
        jLabel30 = new javax.swing.JLabel();
        jLabel31 = new javax.swing.JLabel();
        jtfIndicePrevisionSuc2 = new javax.swing.JTextField();
        jtfPlanesSucursal2 = new javax.swing.JTextField();
        jLabel32 = new javax.swing.JLabel();
        jtfPlanesCorrectivosSuc2 = new javax.swing.JTextField();
        jLabel33 = new javax.swing.JLabel();
        jtfPlanesPreventivosSuc2 = new javax.swing.JTextField();
        jLabel34 = new javax.swing.JLabel();
        jtfIndicadorEficienciaSuc2 = new javax.swing.JTextField();
        jLabel35 = new javax.swing.JLabel();
        jtfIndicadorEficaciaSuc2 = new javax.swing.JTextField();
        jPanel8 = new javax.swing.JPanel();
        jLabel36 = new javax.swing.JLabel();
        jLabel37 = new javax.swing.JLabel();
        jtfIndicePrevisionSuc3 = new javax.swing.JTextField();
        jtfPlanesSucursal3 = new javax.swing.JTextField();
        jLabel38 = new javax.swing.JLabel();
        jtfPlanesCorrectivosSuc3 = new javax.swing.JTextField();
        jLabel39 = new javax.swing.JLabel();
        jtfPlanesPreventivosSuc3 = new javax.swing.JTextField();
        jLabel40 = new javax.swing.JLabel();
        jtfIndicadorEficienciaSuc3 = new javax.swing.JTextField();
        jLabel41 = new javax.swing.JLabel();
        jtfIndicadorEficaciaSuc3 = new javax.swing.JTextField();
        jPanel9 = new javax.swing.JPanel();
        jLabel42 = new javax.swing.JLabel();
        jLabel43 = new javax.swing.JLabel();
        jtfIndicePrevisionSuc4 = new javax.swing.JTextField();
        jtfPlanesSucursal4 = new javax.swing.JTextField();
        jLabel44 = new javax.swing.JLabel();
        jtfPlanesCorrectivosSuc4 = new javax.swing.JTextField();
        jLabel45 = new javax.swing.JLabel();
        jtfPlanesPreventivosSuc4 = new javax.swing.JTextField();
        jLabel46 = new javax.swing.JLabel();
        jtfIndicadorEficienciaSuc4 = new javax.swing.JTextField();
        jLabel47 = new javax.swing.JLabel();
        jtfIndicadorEficaciaSuc4 = new javax.swing.JTextField();
        jPanel10 = new javax.swing.JPanel();
        jLabel15 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        jLabel17 = new javax.swing.JLabel();
        jLabel18 = new javax.swing.JLabel();
        jLabel19 = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        jLabel21 = new javax.swing.JLabel();
        jLabel22 = new javax.swing.JLabel();
        jLabel23 = new javax.swing.JLabel();
        jtfCantidadPlanesRegistrados = new javax.swing.JTextField();
        jtfCantPlanesEfectivos = new javax.swing.JTextField();
        jtfCantInefectivos = new javax.swing.JTextField();
        jtfIndicePrevisionGlobal = new javax.swing.JTextField();
        jtfSucursalMayorPrevision = new javax.swing.JTextField();
        jtfSucursalMayorPlanesCorrectivos = new javax.swing.JTextField();
        jtfSucursalMayorPlanesPreventivos = new javax.swing.JTextField();
        jtfIndicadorEficienciaGlobal = new javax.swing.JTextField();
        jtfIndicadorEfectividadGlobal = new javax.swing.JTextField();
        menuBar = new javax.swing.JMenuBar();
        fileMenu = new javax.swing.JMenu();
        openMenuItem = new javax.swing.JMenuItem();
        exitMenuItem = new javax.swing.JMenuItem();
        editMenu = new javax.swing.JMenu();
        cutMenuItem = new javax.swing.JMenuItem();
        helpMenu = new javax.swing.JMenu();
        contentsMenuItem = new javax.swing.JMenuItem();
        aboutMenuItem = new javax.swing.JMenuItem();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

        jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder("Registrar nuevo Plan"));

        jLabel1.setText("Descripción");

        jtaDescripcionPlan.setColumns(20);
        jtaDescripcionPlan.setRows(5);
        jtaDescripcionPlan.setText("Éste plan es de Miedo!!.");
        jScrollPane2.setViewportView(jtaDescripcionPlan);

        jLabel2.setText("Sucursal");

        jcbSucursales.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Sucursal 1", "Sucursal 2", "Sucursal 3", "Sucursal 4" }));

        jLabel3.setText("Tipo de Plan");

        bgTipoPlan.add(jrbPreventivo);
        jrbPreventivo.setText("Preventivo");

        bgTipoPlan.add(jrbCorrectivo);
        jrbCorrectivo.setSelected(true);
        jrbCorrectivo.setText("Correctivo");

        jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Personal Involucrado"));

        jLabel4.setText("Originador del Plan");

        jbCrearPlan.setText("Crear Plan");

        jbAsignarAdmin.setText("Asignar");
        jbAsignarAdmin.setEnabled(false);

        jbAsignarLider.setText("Asignar");
        jbAsignarLider.setEnabled(false);

        jbAsignarAuditor.setText("Asignar");
        jbAsignarAuditor.setEnabled(false);

        jLabel7.setText("Auditor");

        jLabel6.setText("Líder");

        jLabel5.setText("Administrador");

        jcbOriginador.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        jcbAdministrador.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        jcbAdministrador.setEnabled(false);

        jcbLider.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        jcbLider.setEnabled(false);

        jcbAuditor.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        jcbAuditor.setEnabled(false);

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jLabel4)
                    .addComponent(jLabel5)
                    .addComponent(jLabel6)
                    .addComponent(jLabel7)
                    .addComponent(jcbOriginador, 0, 123, Short.MAX_VALUE)
                    .addComponent(jcbAdministrador, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jcbLider, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jcbAuditor, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jbAsignarAdmin)
                    .addComponent(jbAsignarLider)
                    .addComponent(jbAsignarAuditor)
                    .addComponent(jbCrearPlan))
                .addGap(0, 49, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                .addGap(0, 0, Short.MAX_VALUE)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(jLabel4)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jbCrearPlan)
                        .addGap(25, 25, 25))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(jcbOriginador, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jLabel5)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbAsignarAdmin)
                    .addComponent(jcbAdministrador, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jLabel6)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbAsignarLider)
                    .addComponent(jcbLider, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel7)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbAsignarAuditor)
                    .addComponent(jcbAuditor, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
        );

        jLabel8.setText("Estado:");

        jtfEstado.setEditable(false);
        jtfEstado.setText("Efectivo");

        jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder("Resolución del Plan"));

        jLabel9.setText("Resolución del Auditor");

        jtaResolucionAuditor.setEditable(false);
        jtaResolucionAuditor.setColumns(20);
        jtaResolucionAuditor.setRows(5);
        jScrollPane1.setViewportView(jtaResolucionAuditor);

        jLabel10.setText("El plan se declara:");

        bgPlanEfectivo.add(jrbEfectivo);
        jrbEfectivo.setSelected(true);
        jrbEfectivo.setText("Efectivo");
        jrbEfectivo.setEnabled(false);

        bgPlanEfectivo.add(jrbInefectivo);
        jrbInefectivo.setText("Inefectivo");
        jrbInefectivo.setEnabled(false);

        jbCerrarAuditoria.setText("Cerrar Auditoria");
        jbCerrarAuditoria.setEnabled(false);

        jtbMarcarPlanResuelto.setText("Marcar Plan Resuelto");
        jtbMarcarPlanResuelto.setEnabled(false);

        javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
        jPanel3.setLayout(jPanel3Layout);
        jPanel3Layout.setHorizontalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1)
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel9)
                            .addGroup(jPanel3Layout.createSequentialGroup()
                                .addComponent(jtbMarcarPlanResuelto)
                                .addGap(101, 101, 101)
                                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(jLabel10)
                                    .addGroup(jPanel3Layout.createSequentialGroup()
                                        .addComponent(jrbEfectivo)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                        .addComponent(jrbInefectivo)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                        .addComponent(jbCerrarAuditoria, javax.swing.GroupLayout.PREFERRED_SIZE, 109, javax.swing.GroupLayout.PREFERRED_SIZE)))))
                        .addContainerGap())))
        );
        jPanel3Layout.setVerticalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(jtbMarcarPlanResuelto)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 27, Short.MAX_VALUE)
                        .addComponent(jLabel9))
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addComponent(jLabel10)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jrbEfectivo)
                            .addComponent(jrbInefectivo)
                            .addComponent(jbCerrarAuditoria))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 74, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );

        jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder("Actividades"));

        jLabel11.setText("Descipcion");

        jtaDescripcionActividad.setColumns(20);
        jtaDescripcionActividad.setRows(5);
        jtaDescripcionActividad.setEnabled(false);
        jScrollPane3.setViewportView(jtaDescripcionActividad);

        jpFecha.setBorder(javax.swing.BorderFactory.createTitledBorder("Fecha Propuesta de Resolución"));

        jLabel12.setText("Día:");

        jLabel13.setText("Mes:");

        jsMes.addChangeListener(new javax.swing.event.ChangeListener() {
            public void stateChanged(javax.swing.event.ChangeEvent evt) {
                jsMesStateChanged(evt);
            }
        });

        jLabel14.setText("Año:");

        javax.swing.GroupLayout jpFechaLayout = new javax.swing.GroupLayout(jpFecha);
        jpFecha.setLayout(jpFechaLayout);
        jpFechaLayout.setHorizontalGroup(
            jpFechaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jpFechaLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel12)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jsDia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addComponent(jLabel13)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jsMes, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addComponent(jLabel14)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jsAnio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(409, Short.MAX_VALUE))
        );
        jpFechaLayout.setVerticalGroup(
            jpFechaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jpFechaLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jpFechaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel12)
                    .addComponent(jsDia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel13)
                    .addComponent(jsMes, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel14)
                    .addComponent(jsAnio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jbAgregarActividad.setText("Agregar");
        jbAgregarActividad.setEnabled(false);
        jbAgregarActividad.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbAgregarActividadActionPerformed(evt);
            }
        });

        jbCerrarActividad.setText("Cerrar");
        jbCerrarActividad.setEnabled(false);

        javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jpFecha, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jScrollPane3)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel4Layout.createSequentialGroup()
                                .addComponent(jLabel11)
                                .addGap(0, 589, Short.MAX_VALUE))
                            .addGroup(jPanel4Layout.createSequentialGroup()
                                .addComponent(jbAgregarActividad)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(jbCerrarActividad)))
                        .addContainerGap())))
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel11)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jpFecha, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 11, Short.MAX_VALUE)
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbAgregarActividad)
                    .addComponent(jbCerrarActividad))
                .addContainerGap())
        );

        jtActividades.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null}
            },
            new String [] {
                "Title 1", "Title 2", "Title 3", "Title 4"
            }
        ));
        jtActividades.setEnabled(false);
        jScrollPane4.setViewportView(jtActividades);

        jtPlanes.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null}
            },
            new String [] {
                "Title 1", "Title 2", "Title 3", "Title 4"
            }
        ));
        jScrollPane5.setViewportView(jtPlanes);

        lblSatus.setText("Programa iniciado");

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup()
                                        .addComponent(jLabel2)
                                        .addGap(168, 168, 168))
                                    .addGroup(jPanel2Layout.createSequentialGroup()
                                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addGroup(jPanel2Layout.createSequentialGroup()
                                                .addGap(16, 16, 16)
                                                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                                    .addComponent(jLabel3)
                                                    .addComponent(jrbCorrectivo)
                                                    .addComponent(jrbPreventivo)
                                                    .addComponent(jLabel8)
                                                    .addComponent(jtfEstado, javax.swing.GroupLayout.PREFERRED_SIZE, 184, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                            .addComponent(jcbSucursales, javax.swing.GroupLayout.PREFERRED_SIZE, 166, javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE))
                                        .addGap(18, 18, 18)))
                                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 495, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jPanel4, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 671, Short.MAX_VALUE)))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(jScrollPane5)
                        .addContainerGap())))
            .addComponent(lblSatus, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGap(16, 16, 16)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addGap(12, 12, 12))))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGap(15, 15, 15)
                        .addComponent(jLabel2)
                        .addGap(13, 13, 13)
                        .addComponent(jcbSucursales, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel3)
                        .addGap(7, 7, 7)
                        .addComponent(jrbCorrectivo)
                        .addGap(3, 3, 3)
                        .addComponent(jrbPreventivo)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel8)
                        .addGap(6, 6, 6)
                        .addComponent(jtfEstado, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(jLabel1)))
                .addGap(6, 6, 6)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(27, 27, 27)
                        .addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 106, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(lblSatus, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
        );

        jTabbedPane1.addTab("Registro", jPanel2);

        jPanel6.setBorder(javax.swing.BorderFactory.createTitledBorder("Sucursal 1"));

        jLabel24.setText("Planes registrados:");

        jLabel25.setText("Indice de prevision:");

        jLabel26.setText("Planes correctivos:");

        jLabel27.setText("Planes preventivos:");

        jLabel28.setText("Indicador eficiencia:");

        jLabel29.setText("Indicador Efectividad:");

        jtfPlanesSucursal1.setText("0");

        jtfIndicePrevisionSuc1.setText("0");

        jtfPlanesCorrectivosSuc1.setText("0");

        jtfPlanesPreventivosSuc1.setText("0");

        jtfIndicadorEficienciaSuc1.setText("0");

        jtfIndicadorEficaciaSuc1.setText("0");

        javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);
        jPanel6.setLayout(jPanel6Layout);
        jPanel6Layout.setHorizontalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addComponent(jLabel24)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesSucursal1))
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addComponent(jLabel25)
                        .addGap(18, 18, 18)
                        .addComponent(jtfIndicePrevisionSuc1))
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addComponent(jLabel26)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesCorrectivosSuc1))
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addComponent(jLabel27)
                        .addGap(14, 14, 14)
                        .addComponent(jtfPlanesPreventivosSuc1))
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel28)
                            .addComponent(jLabel29))
                        .addGap(13, 13, 13)
                        .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jtfIndicadorEficaciaSuc1, javax.swing.GroupLayout.DEFAULT_SIZE, 137, Short.MAX_VALUE)
                            .addComponent(jtfIndicadorEficienciaSuc1))))
                .addContainerGap())
        );
        jPanel6Layout.setVerticalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel24)
                    .addComponent(jtfPlanesSucursal1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel25)
                    .addComponent(jtfIndicePrevisionSuc1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel26)
                    .addComponent(jtfPlanesCorrectivosSuc1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel27)
                    .addComponent(jtfPlanesPreventivosSuc1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel28)
                    .addComponent(jtfIndicadorEficienciaSuc1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel29)
                    .addComponent(jtfIndicadorEficaciaSuc1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel7.setBorder(javax.swing.BorderFactory.createTitledBorder("Sucursal 2"));

        jLabel30.setText("Planes registrados:");

        jLabel31.setText("Indice de prevision:");

        jtfIndicePrevisionSuc2.setText("0");

        jtfPlanesSucursal2.setText("0");

        jLabel32.setText("Planes correctivos:");

        jtfPlanesCorrectivosSuc2.setText("0");

        jLabel33.setText("Planes preventivos:");

        jtfPlanesPreventivosSuc2.setText("0");

        jLabel34.setText("Indicador eficiencia:");

        jtfIndicadorEficienciaSuc2.setText("0");

        jLabel35.setText("Indicador Efectividad:");

        jtfIndicadorEficaciaSuc2.setText("0");

        javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
        jPanel7.setLayout(jPanel7Layout);
        jPanel7Layout.setHorizontalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel30)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesSucursal2))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel31)
                        .addGap(18, 18, 18)
                        .addComponent(jtfIndicePrevisionSuc2))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel32)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesCorrectivosSuc2))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel33)
                        .addGap(14, 14, 14)
                        .addComponent(jtfPlanesPreventivosSuc2))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel34)
                            .addComponent(jLabel35))
                        .addGap(13, 13, 13)
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jtfIndicadorEficaciaSuc2, javax.swing.GroupLayout.DEFAULT_SIZE, 137, Short.MAX_VALUE)
                            .addComponent(jtfIndicadorEficienciaSuc2))))
                .addContainerGap())
        );
        jPanel7Layout.setVerticalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel30)
                    .addComponent(jtfPlanesSucursal2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel31)
                    .addComponent(jtfIndicePrevisionSuc2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel32)
                    .addComponent(jtfPlanesCorrectivosSuc2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel33)
                    .addComponent(jtfPlanesPreventivosSuc2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel34)
                    .addComponent(jtfIndicadorEficienciaSuc2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel35)
                    .addComponent(jtfIndicadorEficaciaSuc2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel8.setBorder(javax.swing.BorderFactory.createTitledBorder("Sucursal 3"));

        jLabel36.setText("Planes registrados:");

        jLabel37.setText("Indice de prevision:");

        jtfIndicePrevisionSuc3.setText("0");

        jtfPlanesSucursal3.setText("0");

        jLabel38.setText("Planes correctivos:");

        jtfPlanesCorrectivosSuc3.setText("0");

        jLabel39.setText("Planes preventivos:");

        jtfPlanesPreventivosSuc3.setText("0");

        jLabel40.setText("Indicador eficiencia:");

        jtfIndicadorEficienciaSuc3.setText("0");
        jtfIndicadorEficienciaSuc3.setToolTipText("");

        jLabel41.setText("Indicador Efectividad:");

        jtfIndicadorEficaciaSuc3.setText("0");

        javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);
        jPanel8.setLayout(jPanel8Layout);
        jPanel8Layout.setHorizontalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel8Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel8Layout.createSequentialGroup()
                        .addComponent(jLabel36)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesSucursal3))
                    .addGroup(jPanel8Layout.createSequentialGroup()
                        .addComponent(jLabel37)
                        .addGap(18, 18, 18)
                        .addComponent(jtfIndicePrevisionSuc3))
                    .addGroup(jPanel8Layout.createSequentialGroup()
                        .addComponent(jLabel38)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesCorrectivosSuc3))
                    .addGroup(jPanel8Layout.createSequentialGroup()
                        .addComponent(jLabel39)
                        .addGap(14, 14, 14)
                        .addComponent(jtfPlanesPreventivosSuc3))
                    .addGroup(jPanel8Layout.createSequentialGroup()
                        .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel40)
                            .addComponent(jLabel41))
                        .addGap(13, 13, 13)
                        .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jtfIndicadorEficaciaSuc3, javax.swing.GroupLayout.DEFAULT_SIZE, 137, Short.MAX_VALUE)
                            .addComponent(jtfIndicadorEficienciaSuc3))))
                .addContainerGap())
        );
        jPanel8Layout.setVerticalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel8Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel36)
                    .addComponent(jtfPlanesSucursal3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel37)
                    .addComponent(jtfIndicePrevisionSuc3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel38)
                    .addComponent(jtfPlanesCorrectivosSuc3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel39)
                    .addComponent(jtfPlanesPreventivosSuc3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel40)
                    .addComponent(jtfIndicadorEficienciaSuc3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel41)
                    .addComponent(jtfIndicadorEficaciaSuc3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel9.setBorder(javax.swing.BorderFactory.createTitledBorder("Sucursal 4"));

        jLabel42.setText("Planes registrados:");

        jLabel43.setText("Indice de prevision:");

        jtfIndicePrevisionSuc4.setText("0");

        jtfPlanesSucursal4.setText("0");

        jLabel44.setText("Planes correctivos:");

        jtfPlanesCorrectivosSuc4.setText("0");

        jLabel45.setText("Planes preventivos:");

        jtfPlanesPreventivosSuc4.setText("0");

        jLabel46.setText("Indicador eficiencia:");

        jtfIndicadorEficienciaSuc4.setText("0");

        jLabel47.setText("Indicador Efectividad:");

        jtfIndicadorEficaciaSuc4.setText("0");

        javax.swing.GroupLayout jPanel9Layout = new javax.swing.GroupLayout(jPanel9);
        jPanel9.setLayout(jPanel9Layout);
        jPanel9Layout.setHorizontalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel9Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addComponent(jLabel42)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesSucursal4))
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addComponent(jLabel43)
                        .addGap(18, 18, 18)
                        .addComponent(jtfIndicePrevisionSuc4))
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addComponent(jLabel44)
                        .addGap(18, 18, 18)
                        .addComponent(jtfPlanesCorrectivosSuc4))
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addComponent(jLabel45)
                        .addGap(14, 14, 14)
                        .addComponent(jtfPlanesPreventivosSuc4))
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel46)
                            .addComponent(jLabel47))
                        .addGap(13, 13, 13)
                        .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jtfIndicadorEficaciaSuc4, javax.swing.GroupLayout.DEFAULT_SIZE, 137, Short.MAX_VALUE)
                            .addComponent(jtfIndicadorEficienciaSuc4))))
                .addContainerGap())
        );
        jPanel9Layout.setVerticalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel9Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel42)
                    .addComponent(jtfPlanesSucursal4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel43)
                    .addComponent(jtfIndicePrevisionSuc4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel44)
                    .addComponent(jtfPlanesCorrectivosSuc4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel45)
                    .addComponent(jtfPlanesPreventivosSuc4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel46)
                    .addComponent(jtfIndicadorEficienciaSuc4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel47)
                    .addComponent(jtfIndicadorEficaciaSuc4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel10.setBorder(javax.swing.BorderFactory.createTitledBorder("Estadísticas Globales"));

        jLabel15.setText("Cantidad de planes de acción registrados:");

        jLabel16.setText("Cantidad de planes Efectivos:");

        jLabel17.setText("Cantidad de planes Inefectivos:");

        jLabel18.setText("Indice de previsión:");

        jLabel19.setText("Sucursal con mayor índice de previsión:");

        jLabel20.setText("Sucursal con mayor cantidad de planes correctivos:");

        jLabel21.setText("Sucursal con mayor cantidad de planes preventivos:");

        jLabel22.setText("Indicador de eficiencia:");

        jLabel23.setText("Indicador de Efectividad:");

        jtfCantidadPlanesRegistrados.setText("0");

        jtfCantPlanesEfectivos.setText("0");

        jtfCantInefectivos.setText("0");

        jtfIndicePrevisionGlobal.setText("0");

        jtfIndicadorEficienciaGlobal.setText("0");

        jtfIndicadorEfectividadGlobal.setText("0");

        javax.swing.GroupLayout jPanel10Layout = new javax.swing.GroupLayout(jPanel10);
        jPanel10.setLayout(jPanel10Layout);
        jPanel10Layout.setHorizontalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel10Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel15)
                    .addComponent(jLabel16)
                    .addComponent(jLabel17)
                    .addComponent(jLabel18)
                    .addComponent(jLabel19)
                    .addComponent(jLabel20)
                    .addComponent(jLabel21)
                    .addComponent(jLabel22)
                    .addComponent(jLabel23))
                .addGap(36, 36, 36)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jtfCantidadPlanesRegistrados, javax.swing.GroupLayout.DEFAULT_SIZE, 169, Short.MAX_VALUE)
                    .addComponent(jtfCantPlanesEfectivos)
                    .addComponent(jtfCantInefectivos)
                    .addComponent(jtfIndicePrevisionGlobal)
                    .addComponent(jtfSucursalMayorPrevision)
                    .addComponent(jtfSucursalMayorPlanesCorrectivos)
                    .addComponent(jtfSucursalMayorPlanesPreventivos)
                    .addComponent(jtfIndicadorEficienciaGlobal)
                    .addComponent(jtfIndicadorEfectividadGlobal))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel10Layout.setVerticalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel10Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel15)
                    .addComponent(jtfCantidadPlanesRegistrados, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel16)
                    .addComponent(jtfCantPlanesEfectivos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(15, 15, 15)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel17)
                    .addComponent(jtfCantInefectivos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel18)
                    .addComponent(jtfIndicePrevisionGlobal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel19)
                    .addComponent(jtfSucursalMayorPrevision, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel20)
                    .addComponent(jtfSucursalMayorPlanesCorrectivos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel21)
                    .addComponent(jtfSucursalMayorPlanesPreventivos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel22)
                    .addComponent(jtfIndicadorEficienciaGlobal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel23)
                    .addComponent(jtfIndicadorEfectividadGlobal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(118, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
        jPanel5.setLayout(jPanel5Layout);
        jPanel5Layout.setHorizontalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(jPanel5Layout.createSequentialGroup()
                        .addComponent(jPanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(0, 0, Short.MAX_VALUE)))
                .addContainerGap())
        );
        jPanel5Layout.setVerticalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel9, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel8, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel6, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addGap(18, 18, 18)
                .addComponent(jPanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );

        jTabbedPane1.addTab("Estadísticas", jPanel5);

        fileMenu.setMnemonic('f');
        fileMenu.setText("File");

        openMenuItem.setMnemonic('o');
        openMenuItem.setText("Nuevo Plan...");
        openMenuItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                openMenuItemActionPerformed(evt);
            }
        });
        fileMenu.add(openMenuItem);

        exitMenuItem.setMnemonic('x');
        exitMenuItem.setText("Exit");
        exitMenuItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                exitMenuItemActionPerformed(evt);
            }
        });
        fileMenu.add(exitMenuItem);

        menuBar.add(fileMenu);

        editMenu.setMnemonic('e');
        editMenu.setText("Edit");

        cutMenuItem.setMnemonic('t');
        cutMenuItem.setText("Editar Plan...");
        editMenu.add(cutMenuItem);

        menuBar.add(editMenu);

        helpMenu.setMnemonic('h');
        helpMenu.setText("Help");

        contentsMenuItem.setMnemonic('c');
        contentsMenuItem.setText("Contenidos...");
        helpMenu.add(contentsMenuItem);

        aboutMenuItem.setMnemonic('a');
        aboutMenuItem.setText("Ayuda...");
        helpMenu.add(aboutMenuItem);

        menuBar.add(helpMenu);

        setJMenuBar(menuBar);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jTabbedPane1)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jTabbedPane1)
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void exitMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_exitMenuItemActionPerformed
        System.exit(0);
    }//GEN-LAST:event_exitMenuItemActionPerformed

    private void openMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_openMenuItemActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_openMenuItemActionPerformed

    private void jsMesStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_jsMesStateChanged
        calendario.set(Calendar.MONTH, (int) this.jsMes.getValue() - 1);
        SpinnerNumberModel modelo = (SpinnerNumberModel) this.jsDia.getModel();
        int maximo = calendario.getActualMaximum(Calendar.DATE);
        modelo.setMaximum(maximo);
        modelo.setMinimum(calendario.getActualMinimum(Calendar.DATE));

        if ((int) jsDia.getValue() > maximo) {
            jsDia.setValue(maximo);
        }
    }//GEN-LAST:event_jsMesStateChanged

    private void jbAgregarActividadActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbAgregarActividadActionPerformed
        // TODO add your handling code here:s
    }//GEN-LAST:event_jbAgregarActividadActionPerformed


    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JMenuItem aboutMenuItem;
    private javax.swing.ButtonGroup bgPlanEfectivo;
    private javax.swing.ButtonGroup bgTipoPlan;
    private javax.swing.JMenuItem contentsMenuItem;
    private javax.swing.JMenuItem cutMenuItem;
    private javax.swing.JMenu editMenu;
    private javax.swing.JMenuItem exitMenuItem;
    private javax.swing.JMenu fileMenu;
    private javax.swing.JMenu helpMenu;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel22;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel24;
    private javax.swing.JLabel jLabel25;
    private javax.swing.JLabel jLabel26;
    private javax.swing.JLabel jLabel27;
    private javax.swing.JLabel jLabel28;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel32;
    private javax.swing.JLabel jLabel33;
    private javax.swing.JLabel jLabel34;
    private javax.swing.JLabel jLabel35;
    private javax.swing.JLabel jLabel36;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel38;
    private javax.swing.JLabel jLabel39;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel41;
    private javax.swing.JLabel jLabel42;
    private javax.swing.JLabel jLabel43;
    private javax.swing.JLabel jLabel44;
    private javax.swing.JLabel jLabel45;
    private javax.swing.JLabel jLabel46;
    private javax.swing.JLabel jLabel47;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel10;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JPanel jPanel6;
    private javax.swing.JPanel jPanel7;
    private javax.swing.JPanel jPanel8;
    private javax.swing.JPanel jPanel9;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JButton jbAgregarActividad;
    private javax.swing.JButton jbAsignarAdmin;
    private javax.swing.JButton jbAsignarAuditor;
    private javax.swing.JButton jbAsignarLider;
    private javax.swing.JButton jbCerrarActividad;
    private javax.swing.JButton jbCerrarAuditoria;
    private javax.swing.JButton jbCrearPlan;
    private javax.swing.JComboBox jcbAdministrador;
    private javax.swing.JComboBox jcbAuditor;
    private javax.swing.JComboBox jcbLider;
    private javax.swing.JComboBox jcbOriginador;
    private javax.swing.JComboBox jcbSucursales;
    private javax.swing.JPanel jpFecha;
    private javax.swing.JRadioButton jrbCorrectivo;
    private javax.swing.JRadioButton jrbEfectivo;
    private javax.swing.JRadioButton jrbInefectivo;
    private javax.swing.JRadioButton jrbPreventivo;
    private javax.swing.JSpinner jsAnio;
    private javax.swing.JSpinner jsDia;
    private javax.swing.JSpinner jsMes;
    private javax.swing.JTable jtActividades;
    private javax.swing.JTable jtPlanes;
    private javax.swing.JTextArea jtaDescripcionActividad;
    private javax.swing.JTextArea jtaDescripcionPlan;
    private javax.swing.JTextArea jtaResolucionAuditor;
    private javax.swing.JToggleButton jtbMarcarPlanResuelto;
    private javax.swing.JTextField jtfCantInefectivos;
    private javax.swing.JTextField jtfCantPlanesEfectivos;
    private javax.swing.JTextField jtfCantidadPlanesRegistrados;
    private javax.swing.JTextField jtfEstado;
    private javax.swing.JTextField jtfIndicadorEfectividadGlobal;
    private javax.swing.JTextField jtfIndicadorEficaciaSuc1;
    private javax.swing.JTextField jtfIndicadorEficaciaSuc2;
    private javax.swing.JTextField jtfIndicadorEficaciaSuc3;
    private javax.swing.JTextField jtfIndicadorEficaciaSuc4;
    private javax.swing.JTextField jtfIndicadorEficienciaGlobal;
    private javax.swing.JTextField jtfIndicadorEficienciaSuc1;
    private javax.swing.JTextField jtfIndicadorEficienciaSuc2;
    private javax.swing.JTextField jtfIndicadorEficienciaSuc3;
    private javax.swing.JTextField jtfIndicadorEficienciaSuc4;
    private javax.swing.JTextField jtfIndicePrevisionGlobal;
    private javax.swing.JTextField jtfIndicePrevisionSuc1;
    private javax.swing.JTextField jtfIndicePrevisionSuc2;
    private javax.swing.JTextField jtfIndicePrevisionSuc3;
    private javax.swing.JTextField jtfIndicePrevisionSuc4;
    private javax.swing.JTextField jtfPlanesCorrectivosSuc1;
    private javax.swing.JTextField jtfPlanesCorrectivosSuc2;
    private javax.swing.JTextField jtfPlanesCorrectivosSuc3;
    private javax.swing.JTextField jtfPlanesCorrectivosSuc4;
    private javax.swing.JTextField jtfPlanesPreventivosSuc1;
    private javax.swing.JTextField jtfPlanesPreventivosSuc2;
    private javax.swing.JTextField jtfPlanesPreventivosSuc3;
    private javax.swing.JTextField jtfPlanesPreventivosSuc4;
    private javax.swing.JTextField jtfPlanesSucursal1;
    private javax.swing.JTextField jtfPlanesSucursal2;
    private javax.swing.JTextField jtfPlanesSucursal3;
    private javax.swing.JTextField jtfPlanesSucursal4;
    private javax.swing.JTextField jtfSucursalMayorPlanesCorrectivos;
    private javax.swing.JTextField jtfSucursalMayorPlanesPreventivos;
    private javax.swing.JTextField jtfSucursalMayorPrevision;
    private java.awt.Label lblSatus;
    private javax.swing.JMenuBar menuBar;
    private javax.swing.JMenuItem openMenuItem;
    // End of variables declaration//GEN-END:variables

    /**
     *
     */
    public void inicializarValores() {
        calendario = Calendar.getInstance();
        fechaPropuestaActividad = Calendar.getInstance();

        iniciarValoresCalendario();

        String valoresEnCadena[] = new String[]{"Codigo", "Sucursal", "Tipo de Plan", "Descripcion", "Originador", "Administrador", "Lider",
            "Auditor", "Fecha Registro", "Fecha Asignacion", "Fecha Resolucion", "Resolucion", "Ind. Eficiencia"};
        String valoresEnCadena2[] = new String[]{"Descripcion", "Fecha Propuesta", "Fecha Real de Conclusion"};

        setModeloTablaPlanes(new DefaultTableModel(valoresEnCadena, 0));
        setModeloTablaActividades(new DefaultTableModel(valoresEnCadena2, 0));

        this.setModeloOriginador(new DefaultComboBoxModel());
        this.setModeloAdministrador(new DefaultComboBoxModel());
        this.setModeloLider(new DefaultComboBoxModel());
        this.setModeloAuditor(new DefaultComboBoxModel());

        this.setModeloSucursale(new DefaultComboBoxModel());

        this.jcbOriginador.setModel(modeloOriginador);
        this.jcbAdministrador.setModel(modeloAdministrador);
        this.jcbLider.setModel(modeloLider);
        this.jcbAuditor.setModel(modeloAuditor);

        this.jcbSucursales.setModel(modeloSucursale);

        this.getJbCrearPlan().addActionListener(gestor);


        this.getJbCrearPlan().setActionCommand("CREAR_PLAN");
        this.getJtPlanes().setModel(getModeloTablaPlanes());
        this.getJtPlanes().getSelectionModel().addListSelectionListener(gestor);

        this.jbAsignarAdmin.setActionCommand("ASIGNAR_ADMIN");
        this.jbAsignarAdmin.addActionListener(gestor);

        this.jbAsignarLider.setActionCommand("ASIGNAR_LIDER");
        this.jbAsignarLider.addActionListener(gestor);

        this.jbAsignarAuditor.setActionCommand("ASIGNAR_AUDITOR");
        this.jbAsignarAuditor.addActionListener(gestor);

        this.jrbCorrectivo.setActionCommand("SET_CORRECTIVO");
        this.jrbCorrectivo.addActionListener(gestor);

        this.jrbPreventivo.setActionCommand("SET_PREVENTIVO");
        this.jrbPreventivo.addActionListener(gestor);

        this.getJbAgregarActividad().setActionCommand("AGREGAR_ACTIVIDAD");
        this.getJbAgregarActividad().addActionListener(gestor);

        this.getJbCerrarActividad().setActionCommand("CERRAR_ACTIVIDAD");
        this.getJbCerrarActividad().addActionListener(gestor);

        this.getJtActividades().setModel(getModeloTablaActvidades());

        this.getJtActividades().getSelectionModel().addListSelectionListener(gestor);

        this.jcbSucursales.setActionCommand("ASIGNAR_SUCURSAL");
        this.jcbSucursales.addActionListener(gestor);
        
        this.jtbMarcarPlanResuelto.setActionCommand("MARCAR_PLAN_RESUELTO");
        this.jtbMarcarPlanResuelto.addActionListener(gestor);
        
        this.jbCerrarAuditoria.setActionCommand("CERRAR_AUDITORIA");
        this.jbCerrarAuditoria.addActionListener(gestor);

    }

    /**
     *
     * @param columna
     * @param codigo
     */
    public void actualizarTablaPlanes(int columna, String codigo) {
        this.modeloTablaPlanes.setValueAt(codigo, this.jtPlanes.getSelectedRow(), columna);
    }

    /**
     *
     * @param columna
     * @param valor
     */
    public void actualizarTablaActividades(int columna, String valor)
    {
        this.modeloTablaActividades.setValueAt(valor, jtActividades.getSelectedRow(), columna);
    }

    /**
     *
     * @param estado
     */
    public void actualizarEstadoDePlan(String estado) {
        this.jtfEstado.setText(estado);
    }

    /**
     *
     * @param hab
     */
    public void habilitarLider(boolean hab) {
        this.jcbLider.setEnabled(hab);
        this.jbAsignarLider.setEnabled(hab);
    }

    /**
     *
     * @param hab
     */
    public void habilitarAuditor(boolean hab) {
        this.jcbAuditor.setEnabled(hab);
        this.jbAsignarAuditor.setEnabled(hab);
    }

    /**
     *
     * @param hab
     */
    public void habilitarValoresAuditoria(boolean hab) {
        this.jtbMarcarPlanResuelto.setEnabled(hab);
        this.jrbEfectivo.setEnabled(hab);
        this.jrbInefectivo.setEnabled(hab);
        this.jbCerrarAuditoria.setEnabled(hab);
        this.jtaResolucionAuditor.setEditable(hab);
    }

    /**
     *
     * @param hab
     */
    public void habilitarMarcarPlanResuelto(boolean hab) {
        this.jtbMarcarPlanResuelto.setEnabled(hab);
    }

    /**
     *
     */
    public void iniciarValoresCalendario() {
        int hoy = calendario.get(Calendar.DATE);
        SpinnerModel modeloDia = new SpinnerNumberModel(hoy,
                calendario.getActualMinimum(Calendar.DATE),
                calendario.getActualMaximum(Calendar.DATE),
                1);
        this.jsDia.setModel(modeloDia);

        int mes = calendario.get(Calendar.MONTH) + 1;
        SpinnerModel modeloMes = new SpinnerNumberModel(mes,
                calendario.getActualMinimum(Calendar.MONTH) + 1,
                calendario.getActualMaximum(Calendar.MONTH) + 1,
                1);
        this.jsMes.setModel(modeloMes);

        int anio = calendario.get(Calendar.YEAR);
        SpinnerModel modeloAnio = new SpinnerNumberModel(anio,
                anio - 10,
                anio + 100,
                1);
        this.jsAnio.setModel(modeloAnio);
        this.jsAnio.setEditor(new JSpinner.NumberEditor(jsAnio, "#"));

    }

    /**
     *
     * @param hab
     */
    public void habilitarValoresPlan(boolean hab) {
        this.jcbAdministrador.setEnabled(hab);
        this.jbAsignarAdmin.setEnabled(hab);

    }
    
    /**
     *
     * @param hab
     */
    public void habilitarEdicionPlan(boolean hab)
    {
        this.habilitarAuditor(hab);
        this.habilitarLider(hab);
        this.habilitarMarcarPlanResuelto(hab);
        this.habilitarValoresAuditoria(hab);
        this.habilitarValoresPlan(hab);
        this.habilitarValoresActividad(hab);
    }

    /**
     *
     * @param hab
     */
    public void habilitarValoresActividad(boolean hab) {
        this.getJtActividades().setEnabled(hab);
        this.jtaDescripcionActividad.setEnabled(hab);
        this.jbAgregarActividad.setEnabled(hab);
        //this.jbCerrarActividad.setEnabled(hab);
    }
    
    /**
     *
     * @param hab
     */
    public void habilitarCerrarActividad(boolean hab)
    {
        this.jbCerrarActividad.setEnabled(hab);
    }

    /**
     *
     */
    public void limpiarTablaActvidades() {
           
        int cantidadfilas = getModeloTablaActvidades().getRowCount();
        int indiceMayor = cantidadfilas-1;
        
        for (int i = 0; i < cantidadfilas; i++) {

            getModeloTablaActvidades().removeRow(indiceMayor);
            indiceMayor--;
            //cantidadfilas -= 1; 
        }
    }

    /**
     * *
     * @param modeloOriginador the modeloOriginador to set
     */
    private void setModeloOriginador(DefaultComboBoxModel modeloOriginador) {
        this.modeloOriginador = modeloOriginador;
    }

    /**
     * @param modeloAdministrador the modeloAdministrador to set
     */
    private void setModeloAdministrador(DefaultComboBoxModel modeloAdministrador) {
        this.modeloAdministrador = modeloAdministrador;
    }

    /**
     * @param modeloLider the modeloLider to set
     */
    private void setModeloLider(DefaultComboBoxModel modeloLider) {
        this.modeloLider = modeloLider;
    }

    /**
     * @param modeloAuditor the modeloAuditor to set
     */
    private void setModeloAuditor(DefaultComboBoxModel modeloAuditor) {
        this.modeloAuditor = modeloAuditor;
    }

    /**
     * @param modeloSucursale the modeloSucursale to set
     */
    private void setModeloSucursale(DefaultComboBoxModel modeloSucursale) {
        this.modeloSucursale = modeloSucursale;
    }

    /**
     * @return the jtActividades
     */
    public javax.swing.JTable getJtActividades() {
        return jtActividades;
    }

    /**
     * @return the jtPlanes
     */
    public javax.swing.JTable getJtPlanes() {
        return jtPlanes;
    }

    /**
     * @return the modeloTablaActividades
     */
    public DefaultTableModel getModeloTablaActividades() {
        return modeloTablaActividades;
    }
}
